//
//  YZMQuoteStyle.h
//  YZMicroStock
//
//  Created by wangminhong on 16/4/12.
//  Copyright © 2016年 cqjr. All rights reserved.
//

#import <Foundation/Foundation.h>

#define CHAR_BOUND_COLOR_KEY @"bounds_color_key" //边框线颜色
#define FOCUS_LINE_COLOR_KEY @"focus_line_color" //焦点颜色
#define FOCUS_BACK_COLOR_KEY @"focus_back_color" //背景色
#define FOCUS_TEXT_COLOR_KEY @"focus_text_color" //背景色
#define FOCUS_SEGMENT_LINE_COLOR_KEY  @"focus_segment_line_color" //分割线颜色

#define TREND_LASTCOLOSELINE_COLOR_KEY @"t_lastclose_key"
#define TREND_RISE_COLOR_KEY @"t_rise_key" //涨颜色
#define TREND_FALL_COLOR_KEY @"t_fall_key" //跌颜色
#define TREND_CURRENT_LINE_COLOR_KEY @"t_current_key" //现价线颜色
#define TREND_AVERGE_LINE_COLOR_KEY @"t_averge_key" //均线颜色
#define TREDN_FILL_COLOR_KEY @"t_fill_key"
#define TREND_GRADIENT_START_COLOR @"t_gradient_start" //渐变开始
#define TREND_GRADIENT_END_COLOR @"t_gradient_end" //渐变结束
#define TREND_TIME_COLOR @"t_gradient_end" //时间颜色
#define TREND_VOLUME_COLOR @"volume_color" //量颜色
#define TREND_SCALES_COLOR @"t_scales_color" //


#define KLINE_RISE_COLOR_KEY @"k_rise_key" //高开颜色
#define KLINE_FALL_COLOR_KEY @"k_fall_key" //低开颜色

#define KLINE_AVERGE1_COLOR_KEY @"k_avg1_key" //均线1颜色
#define KLINE_AVERGE2_COLOR_KEY @"k_avg2_key" //均线2颜色
#define KLINE_AVERGE3_COLOR_KEY @"k_avg3_key" //均线3颜色
#define KLINE_AVERGE4_COLOR_KEY @"k_avg4_key" //均线4颜色

#pragma mark -- flashview

#define FLASH_CURRENT_LINE_COLOR_KEY  @"f_current_line_key" //现价线颜色
#define FLASH_TICK_LINE_COLOR_KEY     @"f_tick_line_key"//刻度线颜色
#define FLASH_CURRENT_STRING_COLOR_KEY  @"f_current_string_key" //现价颜色
#define FLASH_TICK_STRING_COLOR_KEY   @"f_tick_string_key" //刻度文字颜色
#define FLASH_TICK_STRING_CENTER_COLOR_KEY  @"f_tick_center_key" //中间刻度文字颜色

@interface YZMQuoteStyle : NSObject

+ (UIColor *)riseColor;
+ (UIColor *)stableColor;
+ (UIColor *)fallColor;

+ (UIColor *)colorForPrice: (double)price basic: (double)basic;

+ (UIColor *)borderColor;

+ (UIColor *)backgroundColorOfRise;
+ (UIColor *)backgroundColorOfFall;
+ (UIColor *)backgroundColorOfStable;

+ (NSDictionary *)trendStyleDict;

+ (NSDictionary *)klineStyleDict;
+ (NSDictionary *)flashStyleDict;
+ (NSDictionary *)tradeTrendStyleDict;

///1.2->+1.20
+ (NSString *)signedStringOfPrice: (double)price;


///0.1->+10%
+ (NSString *)signedStringOfPercentage: (double)value;

///1.1->1.10
+ (NSString *)formatPrice: (double)price;

///100,0000->10万
+ (NSString *)formatNumberValue: (double)value;

///100->1手
+ (NSString *)formatVolumeHand: (double)value;

///100->1
+ (NSString *)formatVolumeValue: (double)value;

@end
